<?php

namespace App\Jobs\Content;

use App\Jobs\Job;
use Carbon\Carbon;

class ChatJob extends Job
{
    protected $data;

    public function __construct($data = [])
    {
        $this->data = [
            'app_id'         => env('CONTENT_APP_ID'),
            'key_id'         => $data['key_id'] ?? 0,
            'add_time'       => Carbon::now()->timestamp,
            'user_id'        => $data['user_id'] ?? 0,
            'user_id_to'     => $data['user_id_to'] ?? 0,
            'room_id'        => $data['room_id'] ?? 0,
            'theme_id'       => $data['theme_id'] ?? 0,
            'content'        => $data['content'] ?? '',
            'content_name'   => $data['content_name'] ?? 0,
            'machine_result' => $data['machine_result'] ?? '',
        ];
    }
}
